home *** CD-ROM | disk | FTP | other *** search
/ Champak 109 / Vol 109.iso / games / flash_ch.swf / scripts / DefineSprite_57 / frame_1 / DoAction.as
Text File  |  2008-11-12  |  498b  |  30 lines

  1. function update()
  2. {
  3.    _height = 576 / (totalLines + 5);
  4.    bottom = top + (96.6 - _height);
  5. }
  6. function appendText(tx)
  7. {
  8.    moveNumber++;
  9.    text = "" + moveNumber + "." + tx + "\n" + text;
  10.    _root.text = title + text;
  11.    totalLines++;
  12.    update();
  13.    gotoBottom();
  14. }
  15. function clearText()
  16. {
  17.    _root.text = title;
  18.    text = "";
  19.    totalLines = 1;
  20.    update();
  21.    moveNumber = 0;
  22. }
  23. totalLines = 0;
  24. title = "\n";
  25. text = "";
  26. top = _Y;
  27. left = _X;
  28. right = _X;
  29. clearText();
  30.